﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace ANZ_AIM_GUI
{
    public partial class frmDataSQM : Form
    {
        public frmDataSQM()
        {
            InitializeComponent();
            LoadDataSQM();
        }

        public void LoadDataSQM()
        {

            DataTable dt1 = new DataTable();
            dt1.Columns.Add("Products Type");
            dt1.Columns.Add("Approved Limit");
            dt1.Columns.Add("TYPE");
            dt1.Columns.Add("Agent (Sales Code 1)");
            dt1.Columns.Add("Sales Name");
            dt1.Columns.Add("Team");
            dt1.Columns.Add("Role");
            dt1.Columns.Add("INCIDENTS");
            dt1.Columns.Add("Incident Code");
            dt1.Columns.Add("Risk Point");
            dt1.Columns.Add("Channel");
            dt1.Columns.Add("source_code");
            dt1.Columns.Add("fullname");
            dt1.Columns.Add("submitdate");
            dt1.Columns.Add("product");
            dt1.Columns.Add("opendate");
            dt1.Columns.Add("Month");

            DataRow datarow1 = dt1.NewRow();
            datarow1["Products Type"] = "N/A";
            datarow1["Approved Limit"] = "";
            datarow1["TYPE"] = "";
            datarow1["Agent (Sales Code 1)"] = "D2W090";
            datarow1["Sales Name"] = "Huynh Thi Cam Hung";
            datarow1["Team"] = "Team W";
            datarow1["Role"] = "Team Leader";
            datarow1["INCIDENTS"] = "Failure to follow process that  prolongs TAT to customer & impacts processing efficiency";
            datarow1["Incident Code"] = "B8";
            datarow1["Risk Point"] = "1";
            datarow1["Channel"] = "DS - HCM 1";
            datarow1["source_code"] = "";
            datarow1["fullname"] = "BUI THI MINH";
            datarow1["submitdate"] = "24/10/2014";
            datarow1["product"] = "Card";
            datarow1["opendate"] = "";
            datarow1["Month"] = "Oct-14";
            dt1.Rows.Add(datarow1);

            DataRow datarow2 = dt1.NewRow();
            datarow2["Products Type"] = "N/A";
            datarow2["Approved Limit"] = "";
            datarow2["TYPE"] = "";
            datarow2["Agent (Sales Code 1)"] = "D2W090";
            datarow2["Sales Name"] = "Huynh Thi Cam Hung";
            datarow2["Team"] = "NA";
            datarow2["Role"] = "Team Leader";
            datarow2["INCIDENTS"] = "Failure to follow process that  prolongs TAT to customer & impacts processing efficiency";
            datarow2["Incident Code"] = "B8";
            datarow2["Risk Point"] = "1";
            datarow2["Channel"] = "DS - HCM 1";
            datarow2["source_code"] = "";
            datarow2["fullname"] = "NGUYEN THANH PHUONG THUY";
            datarow2["submitdate"] = "22/10/2014";
            datarow2["product"] = "Card";
            datarow2["opendate"] = "";
            datarow2["Month"] = "Oct-14";
            dt1.Rows.Add(datarow2);

            dgvData.DataSource = null;
            dgvData.Columns.Clear();
            dgvData.DataSource = dt1;
            dgvData.AutoResizeColumns();

            dgvData.Columns["Risk Point"].DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleRight;
        }
    }
}
